<template>
  <div id="app">
      <h1>Vue Router Demo</h1>
      <hr>
      <div class="wrapper">
        <!--路由的基本使用-->
          <div class="list">
              <router-link class="item" to="/home">去Home</router-link>
              <router-link class="item" to="/about">去About</router-link>
          </div>
          <div class="content">
            <router-view></router-view>
          </div>
      </div>
  </div>
</template>
<script>
export default {
  name: 'App',
  components: {
  },
  data(){
    return{
      message:'hello home',
    }
  }
 
}
</script>

<style>
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  margin-top: 0;
}
#app .wrapper{
  display:flex;
}
.wrapper .list{
  background-color: #f5f5f5;
  width: 400px;
  height: 100px;
}
.wrapper .content{
  width: 100%;
  height: 100px;
}
.wrapper .list .item{
  text-decoration: none;
  display: block;
  box-sizing: border-box;
  width: 100%;
  height: 50%;
  text-align: left;
  background-color: #f5f5f5;
  border: 1px solid;
  border-radius: 5px;
  line-height: 50px;
}
.active{
  background-color: skyblue;
}
</style>
